package com.hmall.common.Cilents;


import com.hmall.common.pojo.Item;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.RequestMapping;

@FeignClient("itemservice")
@RequestMapping("/item")
public interface ItemClient {
    @GetMapping("/{id}")
    public Item selectbyid(@PathVariable Long id);
    @PutMapping("/stock/{itemId}/{num}")
    public void updateStock(@PathVariable Long itemId,@PathVariable Integer num);
}